{% extends 'base.html' %}
{% load static %}
{% block body %}
<div>
    <div class="container">
        <div style="margin-bottom: 10px;margin-top: -10px;">
            <a style="border: 1px solid black;padding: 5px;border-radius: 3px;color: green;" href="/ad/add/">
                <span class="glyphicon glyphicon-plus-sign"></span>添加客户
            </a>
            {% include 'search.html'%}
        </div>
        <div class="panel panel-default" style="background-color: rgb(241, 238, 233);">
            <div class="panel-heading">
                <span class="glyphicon glyphicon-th-list"></span>
                管理员信息
            </div>
            <div style="float: right; width: 500px;margin-top: -7px;">
                <form method="get">
                </form>
            </div>
            <table class="table">
                <thead>
                    <tr>
                        <th>序号</th>
                        <th>管理员账户</th>
                        <th>管理员密码</th>
                        <th>重置密码</th>
                        <th>操作</th>
                    </tr>
                </thead>
                <tbody>
                    {% for admin in queryset %}
                    <tr>
                        <td>{{forloop.counter}}</td>
                        <td>{{admin.username}}</td>
                        <td>********</td>
                        <td><a href="/ad/reset/{{admin.id}}/">
                                <span class="glyphicon glyphicon-transfer">重置密码</span>
                            </a></td>
                        <td>
                            <a style="border: 1px solid black;padding: 1px;border-radius: 3px;"
                                href="/ad/edit/{{admin.id}}/">
                                <span class="glyphicon glyphicon-edit">编辑</span>
                            </a>
                            <a style="border: 1px solid black;padding: 1px;border-radius: 3px;color: red;margin-left: 5px;"
                                href="/ad/delete/{{admin.id}}/">
                                <span class="glyphicon glyphicon-minus-sign">删除</span>
                            </a>
                        </td>
                    </tr>
                    {% endfor %}
                </tbody>
            </table>
            {% include 'page.html' %}
        </div>
    </div>
</div>
{% endblock body %}